group { name: "e/comp/border/default";
   alias: "e/comp/border/default/fast"; // legacy
   images.image: "win_shad_flat.png" COMP;
   parts {
      part { name: "clipper"; type: RECT;
         description { state: "default" 0.0;
            rel1.relative: -1.0  -1.0;
            rel1.offset: -9999 -9999;
            rel2.relative: 2.0   2.0;
            rel2.offset: 9999  9999;
            color: 255 255 255 0; // no cc
            visible: 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 255; // no cc
            visible: 1;
         }
      }
      part { name: "shadow"; type: RECT; mouse_events: 0;
         clip_to: "clipper";
         description { state: "default" 0.0;
            rel.to: "clipper";
         }
         description { state: "hidden" 0.0;
            inherit: "default" 0.0;
            visible: 0;
         }
      }
      part { name: "focus-shadow"; type: RECT;
         clip_to: "shadow";
         description { state: "default" 0.0;
            rel.to: "clipper";
            color_class: "/shadow/normal/comp/win";
         }
         description { state: "focused" 0.0;
            inherit;
            color_class: "/shadow/selected/comp/win";
         }
      }
      WIN_SHAD("e.swallow.content", "focus-shadow", "win_shad_flat.png", 21, 21, 14, 28, 0.5)
      part { name: "shower"; type: SPACER;
         description { state: "default" 0.0;
            rel1.relative: 0.05 0.05;
            rel2.relative: 0.95 0.95;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
            rel1.relative: 0.0  0.0;
            rel2.relative: 1.0  1.0;
         }
      }
      part { name: "trans-clipper"; type: RECT;
         clip_to: "clipper";
         mouse_events: 0;
         description { state: "default" 0.0;
            rel.to: "clipper";
         }
      }
      part { name: "focus-clipper"; type: RECT;
         clip_to: "trans-clipper";
         mouse_events: 0;
         description { state: "default" 0.0;
            rel.to: "clipper";
            color_class: "/bg/normal/comp/win";
         }
         description { state: "focused" 0.0;
            inherit: "default" 0.0;
            color_class: "/bg/selected/comp/win";
         }
      }
      part { name: "e.swallow.content"; type: SWALLOW;
         clip_to: "focus-clipper";
         description { state: "default" 0.0;
            rel.to: "shower";
         }
      }
   }
   programs {
      program { signal: "e,state,shadow,on"; source: "e";
         action: STATE_SET "default" 0.0;
         target: "shadow";
      }
      program { signal: "e,state,shadow,off"; source: "e";
         action: STATE_SET "hidden" 0.0;
         target: "shadow";
      }
      program { signal: "e,state,visible,on"; source: "e";
         action: STATE_SET "visible" 0.0;
         transition: DECELERATE 0.15 USE_DURATION_FACTOR 1;
         target: "clipper";
         target: "shower";
         after: "show2";
      }
      program { name: "show2";
         action: SIGNAL_EMIT "e,action,show,done" "e";
      }
      program { signal: "e,state,visible,off"; source: "e";
         action: STATE_SET "default" 0.0;
         transition: DECELERATE 0.30 USE_DURATION_FACTOR 1;
         target: "clipper";
         target: "shower";
         after: "hide2";
      }
      program { name: "hide2";
         action: SIGNAL_EMIT "e,action,hide,done" "e";
      }
      program { signal: "e,state,focus,on"; source: "e";
         action: STATE_SET "focused" 0.0;
         transition: SINUSOIDAL 0.1 USE_DURATION_FACTOR 1;
         targets: "focus-clipper" "focus-shadow";
      }
      program { signal: "e,state,focus,off"; source: "e";
         action: STATE_SET "default" 0.0;
         transition: SINUSOIDAL 0.1 USE_DURATION_FACTOR 1;
         targets: "focus-clipper" "focus-shadow";
      }
/*
      program { name: "urgent1";
         signal: "e,state,urgent,on"; source: "e";
         action: STATE_SET "focused" 0.0;
         transition: SINUSOIDAL 0.3 USE_DURATION_FACTOR 1;
         target: "glow";
         after: "urgent2";
      }
      program { name: "urgent2";
         action: STATE_SET "default" 0.0;
         transition: SINUSOIDAL 0.3 USE_DURATION_FACTOR 1;
         target: "glow";
         after: "urgent1";
      }
      program {
         signal: "e,state,urgent,off"; source: "e";
         action: STATE_SET "default" 0.0;
         transition: SINUSOIDAL 0.6 CURRENT USE_DURATION_FACTOR 1;
         target: "glow";
      }
 */
   }
}

group { name: "e/comp/border/rotate";
   alias: "e/comp/border/rotate/fast"; // legacy
   inherit: "e/comp/border/default";
   parts {
      part { name: "e.swallow.content";
         description { state: "default";
            map {
               on: 1;
               rotation {
                  z: 0;
               }
            }
         }
         description { state: "focus-out";
            inherit: "default";
            map.rotation.z: 180;
         }
      }
      part {
         name: "shower";
         description { state: "default";
            rel1.relative: 0.0  0.0;
            rel2.relative: 1.0  1.0;
         }
      }
   }
   programs {
      program { signal: "e,state,focus,on"; source: "e";
         action: STATE_SET "default" 0.0;
         target: "e.swallow.content";
         transition: LINEAR 0.3 USE_DURATION_FACTOR 1;
      }
      program { signal: "e,state,focus,off"; source: "e";
         action: STATE_SET "focus-out" 0.0;
         target: "e.swallow.content";
         transition: LINEAR 0.3 USE_DURATION_FACTOR 1;
      }
   }
}

group { name: "e/comp/border/flip";
   alias: "e/comp/border/flip/fast"; // legacy
   inherit: "e/comp/border/rotate";
   parts {
      part { name: "e.swallow.content";
         description { state: "default";
            map {
               on: 1;
               rotation {
                  z: 0;
                  y: 0;
               }
               backface_cull: 1;
            }
         }
         description { state: "focus-out";
            inherit: "default";
            map.rotation {
               z: 0;
               y: 180;
            }
         }
      }
   }
}

group { name: "e/comp/border/popup";
   alias: "e/comp/border/popup/fast"; // legacy
   inherit: "e/comp/border/default";
   parts {
      part { name: "focus-clipper";
         description { state: "default";
         }
      }
   }
}

group { name: "e/comp/border/none";
   parts {
      part { name: "e.swallow.content"; type: SWALLOW;
         description { state: "default" 0.0;
         }
      }
   }
   programs {
      program { signal: "e,state,visible,on"; source: "e";
         action: SIGNAL_EMIT "e,action,show,done" "e";
      }
      program { signal: "e,state,visible,off"; source: "e";
         action: SIGNAL_EMIT "e,action,hide,done" "e";
      }
   }
}

group { name: "e/comp/border/still";
   alias: "e/comp/border/still/fast"; // legacy
   inherit: "e/comp/border/default";
   parts {
      part { name: "shower";
         description { state: "default" 0.0;
            rel1.relative: 0.0 0.0;
            rel2.relative: 1.0 1.0;
         }
      }
   }
}

group { name: "e/comp/border/menu";
   alias: "e/comp/border/menu/fast"; // legacy
   inherit: "e/comp/border/popup";
   parts {
      part { name: "shower";
         description { state: "default" 0.0;
            rel1.relative: 0.05 0.0;
            rel2.relative: 0.95 0.9;
         }
      }
   }
}

group { name: "e/comp/border/everything";
   alias: "e/comp/border/everything/fast"; // legacy
   inherit: "e/comp/border/popup";
   parts {
      part { name: "shower";
         description { state: "default" 0.0;
            rel1.relative: -0.3 -0.3;
            rel2.relative: 1.3 1.3;
         }
      }
   }
}

group { name: "e/comp/border/fullscreen";
   alias: "e/comp/border/fullscreen/fast"; // legacy
   images.image: "screen_circular_shadow.png" COMP;
   data.item: "screen.bg" "fullscreen.bg";
   parts {
      part { name: "clipper"; type: RECT;
         description { state: "default" 0.0;
            rel1.relative: -1.0  -1.0;
            rel1.offset: -9999 -9999;
            rel2.relative: 2.0   2.0;
            rel2.offset: 9999  9999;
            color: 255 255 255 0; // no cc
            visible: 0;
         }
         description { state: "visible1" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 255; // no cc
            visible: 1;
         }
         description { state: "visible2" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 255; // no cc
            visible: 1;
         }
      }
      part { name: "clipper_all"; type: RECT;
         description { state: "default" 0.0;
         }
      }
      part { name: "scr_shadow"; mouse_events: 0;
         clip_to: "clipper_all";
         description { state: "default" 0.0;
            rel1.relative: -1.0 -1.0;
            rel2.relative: 2.0 2.0;
            image.normal: "screen_circular_shadow.png";
            fill.smooth: 0;
            color: 255 255 255 0; // no cc
            visible: 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
            rel1.relative: 0.0 0.0;
            rel2.relative: 1.0 1.0;
            color: 255 255 255 255; // no cc
            visible: 1;
         }
      }
      part { name: "scr_shade"; type: RECT; mouse_events: 0;
         description { state: "default" 0.0;
            color: 0 0 0 0; // no cc
            visible: 0;
         }
         description { state: "visible" 0.0;
            inherit: "default" 0.0;
            color: 0 0 0 255; // no cc
            visible: 1;
         }
      }
      part { name: "shower"; type: SPACER;
         description { state: "default" 0.0;
            rel1.relative: 0.5 0.5;
            rel2.relative: 0.5 0.5;
         }
         description { state: "visible1" 0.0;
            inherit: "default" 0.0;
            rel1.relative: 0.1 0.49;
            rel1.offset: 0 0;
            rel2.relative: 0.9 0.51;
            rel2.offset: -1 -1;
         }
         description { state: "visible2" 0.0;
            inherit: "default" 0.0;
            rel1.relative: 0.0  0.0;
            rel2.relative: 1.0  1.0;
         }
      }
      part { name: "e.swallow.content"; type: SWALLOW;
         clip_to: "clipper";
         description { state: "default" 0.0;
            rel1.to: "shower";
            rel2.to: "shower";
         }
      }
      part { name: "fader"; type: RECT; mouse_events: 0;
         description { state: "default" 0.0;
            rel.to: "e.swallow.content";
            color: 255 255 255 0; // no cc
            visible: 0;
         }
         description { state: "visible1" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 255; // no cc
            visible: 1;
         }
         description { state: "visible2" 0.0;
            inherit: "default" 0.0;
            color: 255 255 255 0; // no cc
            visible: 0;
         }
      }
   }
   programs {
      program {
         name: "visible_on";
         signal: "e,state,visible,on"; source: "e";
         action: STATE_SET "visible" 0.0;
         transition: DECELERATE 0.25 USE_DURATION_FACTOR 1;
         target: "scr_shadow";
         target: "scr_shade";
      }
      program {
         name: "visible_on2";
         signal: "e,state,visible,on"; source: "e";
         action: STATE_SET "visible1" 0.0;
         transition: DECELERATE 0.05 USE_DURATION_FACTOR 1;
         target: "clipper";
         target: "shower";
         target: "fader";
         after: "show2";
      }
      program { name: "show2";
         action: STATE_SET "visible2" 0.0;
         transition: DECELERATE 0.20 USE_DURATION_FACTOR 1;
         target: "clipper";
         target: "shower";
         target: "fader";
         after: "show3";
      }
      program { name: "show3";
         action: SIGNAL_EMIT "e,action,show,done" "e";
      }
      program {
         name: "visible_off";
         signal: "e,state,visible,off"; source: "e";
         action: STATE_SET "default" 0.0;
         transition: DECELERATE 0.25 USE_DURATION_FACTOR 1;
         target: "scr_shadow";
         target: "scr_shade";
      }
      program {
         name: "visible_off2";
         signal: "e,state,visible,off"; source: "e";
         action: STATE_SET "visible1" 0.0;
         transition: DECELERATE 0.2 USE_DURATION_FACTOR 1;
         target: "clipper";
         target: "shower";
         target: "fader";
         after: "hide2";
      }
      program { name: "hide2";
         action: STATE_SET "default" 0.0;
         transition: DECELERATE 0.05 USE_DURATION_FACTOR 1;
         target: "clipper";
         target: "shower";
         target: "fader";
         after: "hide3";
      }
      program { name: "hide3";
         action: SIGNAL_EMIT "e,action,hide,done" "e";
      }
   }
}
